<!DOCTYPE html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!-->
<html class="no-js">
<!--<![endif]-->

<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible"
	content="IE=edge,chrome=1,requiresActiveX=true" />

<meta name="viewport" content="width=device-width,initial-scale=1" />
<title>经纬度定位</title>
</head>
<body>

 
<div id="container" style="width:100%;"></div>
 
<script src="http://webapi.amap.com/maps?v=1.3&key=64db7ceacf3b4d58651064f920e4b704&callback=init"></script>
<script>
    function init(){
    	var href = window.location.href;
		var paramsArr = href.split("?")[1].split("&");
		/* alert((paramsArr[0].split("=")[1].split(",")) instanceof Array); */
		var c = (paramsArr[0].split("=")[1]).split(",");
    	var wh = document.documentElement.clientHeight; 
    	var eh = 20;
        ch = (wh - eh) + "px";
        document.getElementById("container").style.height = ch;
        var map = new AMap.Map('container', {
            center: c,
            zoom: 18
        });
        map.plugin(["AMap.ToolBar"], function() {
            map.addControl(new AMap.ToolBar());
        });
        
        marker = new AMap.Marker({
            position: c,
            title: '位置'
        });
        marker.setMap(map);

    }
</script>


</body>
</html>